package com.getan.boot.module.system.domain.bo;

import com.baomidou.mybatisplus.annotation.TableId;
import com.getan.boot.common.annotation.Dict;
import com.getan.boot.common.domain.GenericBO;
import lombok.Data;
import lombok.EqualsAndHashCode;

import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.NotNull;
import java.time.LocalDate;
import java.util.List;

/**
 * 部门管理
 *
 * @author Bruce.Gong
 * @since 1.0.0-SNAPSHOT
 */
public interface UserBO {

    @EqualsAndHashCode(callSuper = true)
    @Data
    public static class AddBO extends GenericBO {
        @NotEmpty(message = "工号不能为空")
        private String username;
        @NotEmpty(message = "姓名不能为空")
        private String nickname;
        private String avatar;
        private Integer gender;
        private String mobile;
        private LocalDate birthday;
        private String remark;
        // 部门
        private List<Long> deptIds;
        // 角色
        private List<Long> roleIds;
    }

    @EqualsAndHashCode(callSuper = true)
    @Data
    public static class UpdateBO extends GenericBO {
        @NotNull(message = "ID不能为空")
        private Long id;
        @NotEmpty(message = "姓名不能为空")
        private String nickname;
        private String avatar;
        private Integer gender;
        private String mobile;
        private LocalDate birthday;
        private String remark;
        // 部门
        private List<Long> deptIds;
        // 角色
        private List<Long> roleIds;
    }

    @EqualsAndHashCode(callSuper = true)
    @Data
    public static class ResetPwdBO extends GenericBO {
        @NotNull(message = "ID不能为空")
        private Long id;
        @NotEmpty(message = "密码不能为空")
        private String password;
    }

}
